home *** CD-ROM | disk | FTP | other *** search
/ User's Choice Windows CD / User's Choice Windows CD (CMS Software)(1993).iso / utility2 / wine02bx.zip / LISP / UTILS / CL.ELC < prev    next >
Text File  |  1993-03-28  |  50KB  |  504 lines

  1. ;;; compiled by jwz@thalidomide on Thu Jul  2 16:48:27 1992
  2. ;;; from file /u/jwz/emacs19/lisp/utils/cl.el
  3. ;;; emacs version 19.2.1 Lucid.
  4. ;;; bytecomp version 2.07; 17-jun-92.
  5. ;;; optimization is on.
  6. ;;; this file uses opcodes which do not exist in Emacs18.
  7.  
  8. (if (and (boundp 'emacs-version)
  9.      (or (and (boundp 'epoch::version) epoch::version)
  10.          (string-lessp emacs-version "19")))
  11.     (error "This file was compiled for Emacs19."))
  12.  
  13. (byte-code "└┴!ê┬┴!ç" [provide cl require] 2)
  14. (fset 'psetq '(macro . #[(&rest pairs) "G┴ëëëëëë╔ª╩U¼ä╦╠!ê┴뽬@ë9¼ê╦╧╨!\"êBA@BAAë¼V*┴ëë½¥@╙ ëDB BAë¼c+ ƒ ½û@@ BBAA¬f*╓╫ B┴F.ç" [pairs nil i assignments newsyms bindings forms symbols nforms 2 0 error "Odd number of arguments to `psetq'" var ptr "`psetq' expected a symbol, found '%s'." prin1-to-string newsym form gensym ptr2 ptr1 let setq] 8 "\
  15. (psetq {VARIABLE VALUE}...): In parallel, set each VARIABLE to its VALUE.
  16. All the VALUEs are evaluated, and then all the VARIABLEs are set.
  17. Aside from order of evaluation, this is the same as `setq'."]))
  18. (fset 'pair-with-newsyms #[(oldforms) "┴ë┼ !¼Ü╞ ë @D B\nB) Aë)¬a╔ ƒ\nƒ\"+ç" [oldforms nil newsyms bindings ptr endp gentemp newsym G$$_7 values] 4 "\
  19. PAIR-WITH-NEWSYMS OLDFORMS
  20. The top-level components of the list oldforms are paired with fresh
  21. symbols, the pairings list and the newsyms list are returned."])
  22. (fset 'zip-lists #[(evens odds) "\n    @ @╞╚    !¼¢╚ !¼û BB    A A    @ @¬`ƒ-ç" [evens p0 odds p1 even odd nil result endp] 3 "\
  23. Merge two lists EVENS and ODDS, taking elts from each list alternatingly.
  24. EVENS and ODDS are two lists.  ZIP-LISTS constructs a new list, whose
  25. even numbered elements (0,2,...) come from EVENS and whose odd
  26. numbered elements (1,3,...) come from ODDS. 
  27. The construction stops when the shorter list is exhausted."])
  28. (fset 'unzip-list #[(list) "ë@├    !┼┼╚    !¼Ö\nB B╔    !ë@├    !¬b╩ƒƒ\"-ç" [list ptr this cadr next nil evens odds endp cddr values] 4 "\
  29. Extract even and odd elements of LIST into two separate lists.
  30. The argument LIST is separated in two strands, the even and the odd
  31. numbered elements.  Numbering starts with 0, so the first element
  32. belongs in EVENS. No check is made that there is an even number of
  33. elements to start with."])
  34. (fset 'reassemble-argslists #[(argslists) "└┴┬├ \"\"╞╔\n╔Y¼Æ┬╦ \"B\n╠\\ë\n¬iƒ,ç" [apply min mapcar length argslists minlen nil result T$$_22 0 i #[(sublist) "    £ç" [sublist i] 2] 1] 6 "\
  35. (reassemble-argslists ARGSLISTS).
  36. ARGSLISTS is a list of sequences.  Return a list of lists, the first
  37. sublist being all the entries coming from ELT 0 of the original
  38. sublists, the next those coming from ELT 1 and so on, until the
  39. shortest list is exhausted."])
  40. (fset 'build-klist #[(argslist acceptable) "<½å┴G!¼ä┬├!ê <½å┼╞ \"¼ä┬╟!ê╚    ╩ ë ╠!Lê    ½å═!¬ì╧     JC═!)ëA@@┼╞\"¼ê┬╙╘!\"ê╒\" ë@╚╚█!¼¥▄\"ë½çBAë@¬].ç" [argslist evenp error "Odd number of keyword-args" acceptable every keywordp "Second arg should be a list of keywords" nil *mvalues-count* gensym it unzip-list copy-sequence *mvalues-values* 1 T$$_23 forms keywords "Expected keywords, found `%s'" prin1-to-string pairlis auxlist ptr this auxval alist endp assoc] 5 "\
  41. Decode a keyword argument list ARGSLIST for keywords in ACCEPTABLE.
  42. ARGSLIST is a list, presumably the &rest argument of a call, whose
  43. even numbered elements must be keywords.
  44. ACCEPTABLE is a list of keywords, the only ones that are truly acceptable.
  45. The result is an alist containing the arguments named by the keywords
  46. in ACCEPTABLE, or nil if something failed."])
  47. (fset 'duplicate-symbols-p #[(list) "└┴  <½å┼╞ \"¼ä╟╚!ê╔╩ \"ê╔╦ \"ê╔╠ \"ê *ç" [nil gensym propname duplicates list every symbolp error "A list of symbols is needed" mapcar #[(x) "└    \n├#ç" [put x propname 0] 4] #[(x) "└    \n    \nNT#ç" [put x propname] 5] #[(x) "    N┬V¡à Bëç" [x propname 1 duplicates] 2]] 3 "\
  48. Find all symbols appearing more than once in LIST.
  49. Return a list of all such duplicates; `nil' if there are no duplicates."])
  50. (fset 'defkeyword '(macro . #[(x &optional docstring) "9½ç┴┬DEç├─┼!\"ç" [x defconst quote error "`%s' is not a symbol" prin1-to-string] 4 "\
  51. Make symbol X a keyword (symbol whose value is itself).
  52. Optional second argument is a documentation string for it."]))
  53. (fset 'keywordp #[(sym) "9½Ä┴┬!├H─\"½äëLç┼ç" [sym char-equal symbol-name 0 58 nil] 3 "\
  54. Return `t' if SYM is a keyword."])
  55. (fset 'keyword-of #[(sym) "└    !½é    ç    9½ì┬├─    !P!ëëL)ç╞╟╚    !\"ç" [keywordp sym intern ":" symbol-name newsym error "Expected a symbol, not `%s'" prin1-to-string] 5 "\
  56. Return a keyword that is naturally associated with symbol SYM.
  57. If SYM is keyword, the value is SYM.
  58. Otherwise it is a keyword whose name is `:' followed by SYM's name."])
  59. (defvar *gentemp-index* 0 "\
  60. Integer used by gentemp to produce new names.")
  61. (defvar *gentemp-prefix* "T$$_" "\
  62. Names generated by gentemp begin with this string by default.")
  63. (fset 'gentemp #[(&optional prefix oblist) "¼é    \n¼é ─ë¼ÜP╚\\╔\n\"¼k╩\n\"ë½f*ç" [prefix *gentemp-prefix* oblist obarray nil newname newsymbol *gentemp-index* 1 intern-soft intern] 4 "\
  64. Generate a fresh interned symbol.
  65. There are 2 optional arguments, PREFIX and OBLIST.  PREFIX is the
  66. string that begins the new name, OBLIST is the obarray used to search for
  67. old names.  The defaults are just right, YOU SHOULD NEVER NEED THESE
  68. ARGUMENTS IN YOUR OWN CODE."])
  69. (defvar *gensym-index* 0 "\
  70. Integer used by gensym to produce new names.")
  71. (defvar *gensym-prefix* "G$$_" "\
  72. Names generated by gensym begin with this string by default.")
  73. (fset 'gensym #[(&optional prefix) "¼é    ┬├¼ùP╟\\╚ !¼m╔ !ë½i*ç" [prefix *gensym-prefix* nil "" newname newsymbol *gensym-index* 1 intern-soft make-symbol] 3 "\
  74. Generate a fresh uninterned symbol.
  75. There is an  optional argument, PREFIX.  PREFIX is the
  76. string that begins the new name. Most people take just the default,
  77. except when debugging needs suggest otherwise."])
  78. (byte-code "└┴┬├#ê└─┬├#ê└┼┬├#ê└╞┬├#ç" [put case lisp-indent-function 1 ecase when unless] 4)
  79. (fset 'when '(macro . #[(condition &rest body) "└┴┬ D─$ç" [list* if not condition nil body] 5 "\
  80. (when CONDITION . BODY) => evaluate BODY if CONDITION is true."]))
  81. (fset 'unless '(macro . #[(condition &rest body) "└┴\n├ $ç" [list* if condition nil body] 5 "\
  82. (unless CONDITION . BODY) => evaluate BODY if CONDITION is false."]))
  83. (fset 'case '(macro . #[(expr &rest cases) "└ ┬     \"┼    DC╟╚ ƒ\"E*ç" [gentemp newsym case-clausify cases clauses let expr list* cond] 5 "\
  84. (case EXPR . CASES) => evals EXPR, chooses from CASES on that value.
  85. EXPR   -> any form
  86. CASES  -> list of clauses, non empty
  87. CLAUSE -> HEAD . BODY
  88. HEAD   -> t             = catch all, must be last clause
  89.        -> otherwise     = same as t
  90.        -> nil           = illegal
  91.        -> atom          = activated if (eql  EXPR HEAD)
  92.        -> list of atoms = activated if (member EXPR HEAD)
  93. BODY   -> list of forms, implicit PROGN is built around it.
  94. EXPR is evaluated only once."]))
  95. (fset 'ecase '(macro . #[(expr &rest cases) "└ ┬     \"┼ !╞=½ä╟╚!ê╞╟╔╩ D╠    DFD B═     DC╬╧ ƒ\"E*ç" [gentemp newsym case-clausify cases clauses caar t error "No clause-head should be `t' or `otherwise' for `ecase'" "ecase on %s = %s failed to take any branch." quote expr prin1-to-string let list* cond] 6 "\
  96. (ecase EXPR . CASES) => like `case', but error if no case fits.
  97. `t'-clauses are not allowed."]))
  98. (fset 'case-clausify #[(cases newsym) "A@─╞    !¼≡ @ Aë¼ë╔╩╦ !\"ê¬╨╠=¼å═=½Æ╞\n!¼ä╔╬!ê╠BB¬▓:¼É╧╤DEBB¬¥<½É╥╤DEBB¬ê╔╙╦!\"ê*    A\nA    @¬ ,ç" [cases currentpos nextpos curclause nil result endp body head error "Case clauses cannot have null heads: `%s'" prin1-to-string t otherwise "Clause with `t' or `otherwise' head must be last" eql newsym quote cl-member "Don't know how to parse case clause `%s'."] 5 "\
  99. CASE-CLAUSIFY CASES NEWSYM => clauses for a 'cond'
  100. Converts the CASES of a [e]case macro into cond clauses to be
  101. evaluated inside a let that binds NEWSYM.  Returns the clauses in
  102. reverse order."])
  103. (byte-code "└┴┬├#ê└─┬├#ê└┼┬╞#ê└╟┬╞#ê└╚┬╞#ê└╔┬╞#ç" [put do lisp-indent-function 2 do* dolist 1 dotimes do-symbols do-all-symbols] 4)
  104. (fset 'do '(macro . #[(stepforms endforms &rest body) "└    !½ä┬ !ê─    !┼    ! @ A    ╩    ╦╠D═\"BB═!,BBBç" [check-do-stepforms stepforms check-do-endforms endforms extract-do-inits extract-do-steps endbody endcond steplist initlist let while not append body] 7 "\
  105. (do STEPFORMS ENDFORMS . BODY): Iterate BODY, stepping some local variables.
  106. STEPFORMS must be a list of symbols or lists.  In the second case, the
  107. lists must start with a symbol and contain up to two more forms. In
  108. the STEPFORMS, a symbol is the same as a (symbol).  The other 2 forms
  109. are the initial value (def. NIL) and the form to step (def. itself).
  110. The values used by initialization and stepping are computed in parallel.
  111. The ENDFORMS are a list (CONDITION . ENDBODY).  If the CONDITION
  112. evaluates to true in any iteration, ENDBODY is evaluated and the last
  113. form in it is returned.
  114. The BODY (which may be empty) is evaluated at every iteration, with
  115. the symbols of the STEPFORMS bound to the initial or stepped values."]))
  116. (fset 'do* '(macro . #[(stepforms endforms &rest body) "└    !½ä┬ !ê─    !┼    ! @ A    ╩    ╦╠D═\"BB═!,BBBç" [check-do-stepforms stepforms check-do-endforms endforms extract-do-inits extract-do*-steps endbody endcond steplist initlist let* while not append body] 7 "\
  117. `do*' is to `do' as `let*' is to `let'.
  118. STEPFORMS must be a list of symbols or lists.  In the second case, the
  119. lists must start with a symbol and contain up to two more forms. In
  120. the STEPFORMS, a symbol is the same as a (symbol).  The other 2 forms
  121. are the initial value (def. NIL) and the form to step (def. itself).
  122. Initializations and steppings are done in the sequence they are written.
  123. The ENDFORMS are a list (CONDITION . ENDBODY).  If the CONDITION
  124. evaluates to true in any iteration, ENDBODY is evaluated and the last
  125. form in it is returned.
  126. The BODY (which may be empty) is evaluated at every iteration, with
  127. the symbols of the STEPFORMS bound to the initial or stepped values."]))
  128. (fset 'check-do-stepforms #[(forms) "<¼ç┴┬├!\"ç─┼\"ç" [forms error "Init/Step form for do[*] should be a list, not `%s'" prin1-to-string mapcar #[(entry) "9¼Å<½ì@9½êG┴W½é┬ç├─┼!\"ç" [entry 4 t error "Init/Step must be symbol or (symbol [init [step]]), not `%s'" prin1-to-string] 4]] 4 "\
  129. True if FORMS is a valid stepforms for the do[*] macro (q.v.)"])
  130. (fset 'check-do-endforms #[(forms) "<½é┴ç┬├─!\"ç" [forms t error "Termination form for do macro should be a list, not `%s'" prin1-to-string] 4 "\
  131. True if FORMS is a valid endforms for the do[*] macro (q.v.)"])
  132. (fset 'extract-do-inits #[(forms) "└┴\n\"ç" [mapcar #[(entry) "9½ä┴Dç<¡å@┬!Dç" [entry nil cadr] 3] forms] 3 "\
  133. Returns a list of the initializations (for do) in FORMS
  134. -a stepforms, see the do macro-. Forms is assumed syntactically valid."])
  135. (fset 'extract-do-steps #[(forms) "└┴\n!BCç" [psetq select-stepping-forms forms] 3 "\
  136. EXTRACT-DO-STEPS FORMS => an s-expr
  137. FORMS is the stepforms part of a DO macro (q.v.).  This function
  138. constructs an s-expression that does the stepping at the end of an
  139. iteration."])
  140. (fset 'extract-do*-steps #[(forms) "└┴\n!BCç" [setq select-stepping-forms forms] 3 "\
  141. EXTRACT-DO*-STEPS FORMS => an s-expr
  142. FORMS is the stepforms part of a DO* macro (q.v.).  This function
  143. constructs an s-expression that does the stepping at the end of an
  144. iteration."])
  145. (fset 'select-stepping-forms #[(forms) "└    └ ½¥ @ë<½É\nG┼U½è╞╟\n!\n@D \" Aë¼c ƒ+ç" [nil forms entry ptr result 3 append caddr] 4 "\
  146. Separate only the forms that cause stepping."])
  147. (fset 'dolist '(macro . #[(stepform &rest body) "<¼ë┴┬├!\"ꬣ@9¼è┴─├@!\"ê¬ìG┼V½ç┴╞├!\"ê@╚!    ╩! ╠═╬╧CBBD    E╤╥DC EE+ç" [stepform error "Stepform for `dolist' should be (VAR LIST [RESULT]), not `%s'" prin1-to-string "First component of stepform should be a symbol, not `%s'" 3 "Too many components in stepform `%s'" var cadr listform caddr resultform progn mapcar function lambda body let nil] 6 "\
  148. (dolist (VAR LIST [RESULTFORM]) . BODY): do BODY for each elt of LIST.
  149. The RESULTFORM defaults to nil.  The VAR is bound to successive
  150. elements of the value of LIST and remains bound (to the nil value) when the
  151. RESULTFORM is evaluated."]))
  152. (fset 'dotimes '(macro . #[(stepform &rest body) "<¼ë┴┬├!\"ꬣ@9¼è┴─├@!\"ê¬ìG┼V½ç┴╞├!\"ê@╚!    ╩! ╠ ╬    DC╧╨╤╥╙EEC╘E D$E,ç" [stepform error "Stepform for `dotimes' should be (VAR COUNT [RESULT]), not `%s'" prin1-to-string "First component of stepform should be a symbol, not `%s'" 3 "Too many components in stepform `%s'" var cadr countform caddr resultform gentemp newsym let* list* do* 0 + 1 >= body] 9 "\
  153. (dotimes (VAR COUNTFORM [RESULTFORM]) .  BODY): Repeat BODY, counting in VAR.
  154. The COUNTFORM should return a positive integer.  The VAR is bound to
  155. successive integers from 0 to COUNTFORM-1 and the BODY is repeated for
  156. each of them.  At the end, the RESULTFORM is evaluated and its value
  157. returned. During this last evaluation, the VAR is still bound, and its
  158. value is the number of times the iteration occurred. An omitted RESULTFORM
  159. defaults to nil."]))
  160. (fset 'do-symbols '(macro . #[(stepform &rest body) "<¼ë┴┬├!\"ꬣ@9¼è┴─├@!\"ê¬ìG┼V½ç┴╞├!\"ê@╚!    ╩! ╠═╬╧CBBD    E╤╥DC EE+ç" [stepform error "Stepform for `do-symbols' should be (VAR OBARRAY [RESULT]), not `%s'" prin1-to-string "First component of stepform should be a symbol, not `%s'" 3 "Too many components in stepform `%s'" var cadr oblist caddr resultform progn mapatoms function lambda body let nil] 6 "\
  161. (do_symbols (VAR [OBARRAY [RESULTFORM]]) . BODY)
  162. The VAR is bound to each of the symbols in OBARRAY (def. obarray) and
  163. the BODY is repeatedly performed for each of those bindings. At the
  164. end, RESULTFORM (def. nil) is evaluated and its value returned.
  165. During this last evaluation, the VAR is still bound and its value is nil.
  166. See also the function `mapatoms'."]))
  167. (fset 'do-all-symbols '(macro . #[(stepform &rest body) "└┴\n@├─\n!E#ç" [list* do-symbols stepform obarray cadr body] 6 "\
  168. (do-all-symbols (VAR [RESULTFORM]) . BODY)
  169. Is the same as (do-symbols (VAR obarray RESULTFORM) . BODY)."]))
  170. (fset 'loop '(macro . #[(&rest body) "<¼ä┴┬!ç├─\"ê┼╞BBç" [body error "Body of `loop' should be a list of lists or nil" mapcar #[(component) "<?¡â┴┬!ç" [component error "Components of `loop' should be lists"] 2] while t] 3 "\
  171. (loop . BODY) repeats BODY indefinitely and does not return.
  172. Normally BODY uses `throw' or `signal' to cause an exit.
  173. The forms in BODY should be lists, as non-lists are reserved for new features."]))
  174. (fset 'first #[(x) "@ç" [x] 1 "\
  175. Synonym for `car'"])
  176. (fset 'second #[(x) "A@ç" [x] 1 "\
  177. Return the second element of the list LIST."])
  178. (fset 'third #[(x) "└    8ç" [2 x] 2 "\
  179. Return the third element of the list LIST."])
  180. (fset 'fourth #[(x) "└    8ç" [3 x] 2 "\
  181. Return the fourth element of the list LIST."])
  182. (fset 'fifth #[(x) "└    8ç" [4 x] 2 "\
  183. Return the fifth element of the list LIST."])
  184. (fset 'sixth #[(x) "└    8ç" [5 x] 2 "\
  185. Return the sixth element of the list LIST."])
  186. (fset 'seventh #[(x) "└    8ç" [6 x] 2 "\
  187. Return the seventh element of the list LIST."])
  188. (fset 'eighth #[(x) "└    8ç" [7 x] 2 "\
  189. Return the eighth element of the list LIST."])
  190. (fset 'ninth #[(x) "└    8ç" [8 x] 2 "\
  191. Return the ninth element of the list LIST."])
  192. (fset 'tenth #[(x) "└    8ç" [9 x] 2 "\
  193. Return the tenth element of the list LIST."])
  194. (fset 'rest #[(x) "Aç" [x] 1 "\
  195. Synonym for `cdr'"])
  196. (fset 'endp #[(x) "<½â?ç┴┬├!\"ç" [x error "endp received a non-cons, non-null argument `%s'" prin1-to-string] 4 "\
  197. t if X is nil, nil if X is a cons; error otherwise."])
  198. (fset 'last #[(x) "<¼ä┴┬!êëA┼ !¼É A Aë*¬k *ç" [x error "Arg to `last' must be a list" next-cons current-cons endp G$$_8 G$$_9] 3 "\
  199. Returns the last link in the list LIST."])
  200. (fset 'list-length #[(x) "└    ë┬ ¼┬╟!½ä╚¬¿╟A!½è╔\\╚¬ÿ =½ì└V½ç┬╚¬å╩\\╦! A ë *¬;,ç" [0 x nil ready slow fast n endp t 1 2 cddr G$$_10 G$$_11] 5 "\
  201. Returns the length of a non-circular list, or `nil' for a circular one."])
  202. (fset 'cl-member #[(item list) "┴ë ¼ò┼ !¼É @=½ä╟  A¬h\n+ç" [list nil result done ptr endp item t] 3 "\
  203. Look for ITEM in LIST; return first link in LIST whose car is `eql' to ITEM."])
  204. (fset 'butlast #[(list &optional n) "¼é┴┬┬ !¢!ç" [n 1 reverse list] 4 "\
  205. Return a new list like LIST but sans the last N elements.
  206. N defaults to 1.  If the list doesn't have N elements, nil is returned."])
  207. (fset 'list* #[(arg &rest others) "¼é    ç    B├\n!┼\n!┼ !@íê +ç" [others arg allargs butlast front last back] 2 "\
  208. Return a new list containing the first arguments consed onto the last arg.
  209. Thus, (list* 1 2 3 '(a b)) returns (1 2 3 a b)."])
  210. (fset 'adjoin #[(item list) "└    \n\"½é\nç    \nBç" [cl-member item list] 3 "\
  211. Return a list which contains ITEM but is otherwise like LIST.
  212. If ITEM occurs in LIST, the value is LIST.  Otherwise it is (cons ITEM LIST).
  213. When comparing ITEM against elements, `eql' is used."])
  214. (fset 'ldiff #[(list sublist) "└    ─\n!¼ô\n=¼Ä\n@ B\nAë)¬h╟ !*ç" [nil list curcons result endp sublist G$$_12 reverse] 3 "\
  215. Return a new list like LIST but sans SUBLIST.
  216. SUBLIST must be one of the links in LIST; otherwise the value is LIST itself."])
  217. (fset 'caar #[(X) "@@ç" [X] 1 "\
  218. Return the car of the car of X."])
  219. (fset 'cadr #[(X) "A@ç" [X] 1 "\
  220. Return the car of the cdr of X."])
  221. (fset 'cdar #[(X) "@Aç" [X] 1 "\
  222. Return the cdr of the car of X."])
  223. (fset 'cddr #[(X) "AAç" [X] 1 "\
  224. Return the cdr of the cdr of X."])
  225. (fset 'caaar #[(X) "@@@ç" [X] 1 "\
  226. Return the car of the car of the car of X."])
  227. (fset 'caadr #[(X) "A@@ç" [X] 1 "\
  228. Return the car of the car of the cdr of X."])
  229. (fset 'cadar #[(X) "@A@ç" [X] 1 "\
  230. Return the car of the cdr of the car of X."])
  231. (fset 'cdaar #[(X) "@@Aç" [X] 1 "\
  232. Return the cdr of the car of the car of X."])
  233. (fset 'caddr #[(X) "AA@ç" [X] 1 "\
  234. Return the car of the cdr of the cdr of X."])
  235. (fset 'cdadr #[(X) "A@Aç" [X] 1 "\
  236. Return the cdr of the car of the cdr of X."])
  237. (fset 'cddar #[(X) "@AAç" [X] 1 "\
  238. Return the cdr of the cdr of the car of X."])
  239. (fset 'cdddr #[(X) "AAAç" [X] 1 "\
  240. Return the cdr of the cdr of the cdr of X."])
  241. (fset 'caaaar #[(X) "@@@@ç" [X] 1 "\
  242. Return the car of the car of the car of the car of X."])
  243. (fset 'caaadr #[(X) "A@@@ç" [X] 1 "\
  244. Return the car of the car of the car of the cdr of X."])
  245. (fset 'caadar #[(X) "@A@@ç" [X] 1 "\
  246. Return the car of the car of the cdr of the car of X."])
  247. (fset 'cadaar #[(X) "@@A@ç" [X] 1 "\
  248. Return the car of the cdr of the car of the car of X."])
  249. (fset 'cdaaar #[(X) "@@@Aç" [X] 1 "\
  250. Return the cdr of the car of the car of the car of X."])
  251. (fset 'caaddr #[(X) "AA@@ç" [X] 1 "\
  252. Return the car of the car of the cdr of the cdr of X."])
  253. (fset 'cadadr #[(X) "A@A@ç" [X] 1 "\
  254. Return the car of the cdr of the car of the cdr of X."])
  255. (fset 'cdaadr #[(X) "A@@Aç" [X] 1 "\
  256. Return the cdr of the car of the car of the cdr of X."])
  257. (fset 'caddar #[(X) "@AA@ç" [X] 1 "\
  258. Return the car of the cdr of the cdr of the car of X."])
  259. (fset 'cdadar #[(X) "@A@Aç" [X] 1 "\
  260. Return the cdr of the car of the cdr of the car of X."])
  261. (fset 'cddaar #[(X) "@@AAç" [X] 1 "\
  262. Return the cdr of the cdr of the car of the car of X."])
  263. (fset 'cadddr #[(X) "AAA@ç" [X] 1 "\
  264. Return the car of the cdr of the cdr of the cdr of X."])
  265. (fset 'cddadr #[(X) "A@AAç" [X] 1 "\
  266. Return the cdr of the cdr of the car of the cdr of X."])
  267. (fset 'cdaddr #[(X) "AA@Aç" [X] 1 "\
  268. Return the cdr of the car of the cdr of the cdr of X."])
  269. (fset 'cdddar #[(X) "@AAAç" [X] 1 "\
  270. Return the cdr of the cdr of the cdr of the car of X."])
  271. (fset 'cddddr #[(X) "AAAAç" [X] 1 "\
  272. Return the cdr of the cdr of the cdr of the cdr of X."])
  273. (fset 'setnth #[(n list newval) "    ¢\náç" [n list newval] 2 "\
  274. Set (nth N LIST) to NEWVAL.  Returns NEWVAL."])
  275. (fset 'setnthcdr #[(n list newval) "┴W½à┬├\"ç┴U½î @áê Aíêç╞Z ¢íç" [n 0 error "N must be 0 or greater, not %d" list newval 1] 3 "\
  276. SETNTHCDR N LIST NEWVAL => NEWVAL
  277. As a side effect, sets the Nth cdr of LIST to NEWVAL."])
  278. (fset 'acons #[(key item alist) "    B\nBç" [key item alist] 2 "\
  279. Return a new alist with KEY paired with ITEM; otherwise like ALIST.
  280. Does not copy ALIST."])
  281. (fset 'pairlis #[(keys data &optional alist) "G    GU¼ä┬├!ê     @@    ╩ !¼Ü╦    #     AA @@¬a    -ç" [keys data error "Keys and data should be the same length" kptr dptr key item alist result endp acons] 4 "\
  282. Return a new alist with each elt of KEYS paired with an elt of DATA;
  283. optional 3rd arg ALIST is nconc'd at the end.  KEYS and DATA must
  284. have the same length."])
  285. (byte-code "└┴┬├─┼╞╟╚╔    ╩\n╦ └ç" [:test :test-not :key :predicate :start :end :start1 :start2 :end1 :end2 :count :from-end] 1)
  286. (fset 'some #[(pred seq &rest moreseqs) "└┴\n \"!┼┼┼ ë    @\n¼ú╦    !¼¥╠\n\"ë½ç╬    Aë    @\n¬Y.ç" [reassemble-argslists list* seq moreseqs args nil ready result applyval remaining current endp apply pred t] 5 "\
  287. Test PREDICATE on each element of SEQUENCE; is it ever non-nil?
  288. Extra args are additional sequences; PREDICATE gets one arg from each
  289. sequence and we advance down all the sequences together in lock-step.
  290. A sequence means either a list or a vector."])
  291. (fset 'every #[(pred seq &rest moreseqs) "└┴\n \"!┼╟┼     ë\n@ ¼ó╠\n!¼£═ \"ë    ¼å╟┼\nAë\n@ ¬Z.ç" [reassemble-argslists list* seq moreseqs args nil ready t result applyval remaining current endp apply pred] 5 "\
  292. Test PREDICATE on each element of SEQUENCE; is it always non-nil?
  293. Extra args are additional sequences; PREDICATE gets one arg from each
  294. sequence and we advance down all the sequences together in lock-step.
  295. A sequence means either a list or a vector."])
  296. (fset 'notany #[(pred seq &rest moreseqs) "└┴\n \"!┼╟┼     ë\n@ ¼ó╠\n!¼£═ \"ë    ½å╟┼\nAë\n@ ¬Z.ç" [reassemble-argslists list* seq moreseqs args nil ready t result applyval remaining current endp apply pred] 5 "\
  297. Test PREDICATE on each element of SEQUENCE; is it always nil?
  298. Extra args are additional sequences; PREDICATE gets one arg from each
  299. sequence and we advance down all the sequences together in lock-step.
  300. A sequence means either a list or a vector."])
  301. (fset 'notevery #[(pred seq &rest moreseqs) "└┴\n \"!┼┼┼ ë    @\n¼ó╦    !¼£╠\n\"ë¼å╬╬    Aë    @\n¬Z.ç" [reassemble-argslists list* seq moreseqs args nil ready result applyval remaining current endp apply pred t] 5 "\
  302. Test PREDICATE on each element of SEQUENCE; is it sometimes nil?
  303. Extra args are additional sequences; PREDICATE gets one arg from each
  304. sequence and we advance down all the sequences together in lock-step.
  305. A sequence means either a list or a vector."])
  306. (fset 'setelt #[(seq n newval) "G\n├W¼à\n    Y½ç─┼\n    #¬₧<½ê╞\n#¬Æ╚!½ç\nI¬å─╔╩!\")ç" [seq l n 0 error "N(%d) should be between 0 and %d" setnth newval arrayp "SEQ should be a sequence, not `%s'" prin1-to-string] 4 "\
  307. In SEQUENCE, set the Nth element to NEWVAL.  Returns NEWVAL.
  308. A sequence means either a list or a vector."])
  309. (fset 'extract-from-klist #[(key klist &optional default) "└    \n\"Aë«ü )ç" [assoc key klist retrieved default] 4 "\
  310. EXTRACT-FROM-KLIST KEY KLIST [DEFAULT] => value of KEY or DEFAULT
  311. Extract value associated with KEY in KLIST (return DEFAULT if nil)."])
  312. (fset 'add-to-klist #[(key item klist) "└    \n #ëç" [acons key item klist] 4 "\
  313. ADD-TO-KLIST KEY ITEM KLIST => new KLIST
  314. Add association (KEY . ITEM) to KLIST."])
  315. (fset 'elt-satisfies-test-p #[(item elt klist) "└    \n\"└ \n\"└ \n┼#ë½î    \n!\"¬ù½ì    \n!\"?¬å╦╠═\n!\"+ç" [extract-from-klist :test klist :test-not :key identity keyfn test-not test item elt error "Neither :test nor :test-not in `%s'" prin1-to-string] 7 "\
  316. ELT-SATISFIES-TEST-P ITEM ELT KLIST => t or nil
  317. KLIST encodes a keyword-arguments test, as in CH. 14 of CLtL.
  318. True if the given ITEM and ELT satisfy the test."])
  319. (fset 'elt-satisfies-if-p #[(item klist) "└    \n\"└ ─\"ë!\"*ç" [extract-from-klist :predicate klist :key identity keyfn predicate item elt] 5 "\
  320. ELT-SATISFIES-IF-P ITEM KLIST => t or nil
  321. True if an -if style function was called and ITEM satisfies the
  322. predicate under :predicate in KLIST."])
  323. (fset 'elt-satisfies-if-not-p #[(item klist) "└    \n\"└ ─\"ë!\"*?ç" [extract-from-klist :predicate klist :key identity keyfn predicate item elt] 5 "\
  324. ELT-SATISFIES-IF-NOT-P ITEM KLIST => t or nil
  325. KLIST encodes a keyword-arguments test, as in CH. 14 of CLtL.
  326. True if an -if-not style function was called and ITEM does not satisfy
  327. the predicate under :predicate in KLIST."])
  328. (fset 'elts-match-under-klist-p #[(e1 e2 klist) "└    \n\"└ \n\"└ \n┼#ë½Å    !\n!\"¬Ü½É    !\n!\"?¬å╦╠═\n!\"+ç" [extract-from-klist :test klist :test-not :key identity keyfn test-not test e1 e2 error "Neither :test nor :test-not in `%s'" prin1-to-string] 7 "\
  329. ELTS-MATCH-UNDER-KLIST-P E1 E2 KLIST => t or nil
  330. KLIST encodes a keyword-arguments test, as in CH. 14 of CLtL.
  331. True if elements E1 and E2 match under the tests encoded in KLIST."])
  332. (byte-code "└┴┬├#ê└─┬├#ê└┼┬╞#ê└╟┬╚#ê└╔┬╚#ç" [put multiple-value-bind lisp-indent-function 2 multiple-value-setq multiple-value-list nil multiple-value-call 1 multiple-value-prog1] 4)
  333. (defvar *mvalues-values* nil "\
  334. Most recently returned multiple-values")
  335. (defvar *mvalues-count* nil "\
  336. Count of multiple-values returned, or nil if the mechanism was not used")
  337. (fset 'values #[(&rest val-forms) "ëG    @ç" [val-forms *mvalues-values* *mvalues-count*] 2 "\
  338. Produce multiple values (zero or more).  Each arg is one value.
  339. See also `multiple-value-bind', which is one way to examine the
  340. multiple values produced by a form.  If the containing form or caller
  341. does not check specially to see multiple values, it will see only
  342. the first value."])
  343. (fset 'values-list #[(&optional val-forms) "<¼ç┴┬├!\"êëG @ç" [val-forms error "Argument to values-list must be a list, not `%s'" prin1-to-string *mvalues-values* *mvalues-count*] 5 "\
  344. Produce multiple values (zero or mode).  Each element of LIST is one value.
  345. This is equivalent to (apply 'values LIST)."])
  346. (fset 'multiple-value-list '(macro . #[(form) "└┴┬├E─┼╞DC╟┼E╔┬╩╦D└┴┬╠E┴╦═╬┼DDE╩╦DFFFEç" [progn setq *mvalues-count* nil let it (gensym) set form if copy-sequence *mvalues-values* 1 list symbol-value] 15 "\
  347. Execute FORM and return a list of all the (multiple) values FORM produces.
  348. See `values' and `multiple-value-bind'."]))
  349. (fset 'multiple-value-call '(macro . #[(function &rest args) "└ └ ├─┼ !D╞    ╟DC╚\n╔\nD    E╦    ╠    ═┼\nDDEEEEE*ç" [gentemp result arg apply function eval let* nil dolist quote args setq append multiple-value-list] 13 "\
  350. Call FUNCTION on all the values produced by the remaining arguments.
  351. (multiple-value-call '+ (values 1 2) (values 3 4)) is 10."]))
  352. (fset 'multiple-value-bind '(macro . #[(vars form &rest body) "└ ┬     \"┼╞    ╟DD B    #*ç" [gentemp vals mv-bind-clausify vars clauses list* let* multiple-value-list form body] 5 "\
  353. Bind VARS to the (multiple) values produced by FORM, then do BODY.
  354. VARS is a list of variables; each is bound to one of FORM's values.
  355. If FORM doesn't make enough values, the extra variables are bound to nil.
  356. (Ordinary forms produce only one value; to produce more, use `values'.)
  357. Extra values are ignored.
  358. BODY (zero or more forms) is executed with the variables bound,
  359. then the bindings are unwound."]))
  360. (fset 'multiple-value-setq '(macro . #[(vars form) "└ ┬     \"┼    ╞DDC╚╔╩ \"BE*ç" [gentemp vals mv-bind-clausify vars clauses let* multiple-value-list form setq apply append] 6 "\
  361. Set VARS to the (multiple) values produced by FORM.
  362. VARS is a list of variables; each is set to one of FORM's values.
  363. If FORM doesn't make enough values, the extra variables are set to nil.
  364. (Ordinary forms produce only one value; to produce more, use `values'.)
  365. Extra values are ignored."]))
  366. (fset 'multiple-value-prog1 '(macro . #[(form &rest body) "└ ┬    ├ DDC┼╟    DC\")BBç" [gentemp heldvalues let* multiple-value-list form append body values-list] 6 "\
  367. Evaluate FORM, then BODY, then produce the same values FORM produced.
  368. Thus, (multiple-value-prog1 (values 1 2) (foobar)) produces values 1 and 2.
  369. This is like `prog1' except that `prog1' would produce only one value,
  370. which would be the first of FORM's values."]))
  371. (fset 'mv-bind-clausify #[(vars vals) "<½å┴┬\"½ç├─┼!\"êG╟    ╩ ╩    Y¼Ö 8╠ EDB ╬\\ë ¬b,ç" [vars notevery symbolp error "Expected a list of symbols, not `%s'" prin1-to-string nvars nil clauses T$$_24 0 n nth vals 1] 5 "\
  372. MV-BIND-CLAUSIFY VARS VALS => Auxiliary list
  373. Forms a list of pairs `(,(nth i vars) (nth i vals)) for i from 0 to
  374. the length of VARS (a list of symbols).  VALS is just a fresh symbol."])
  375. (fset 'plusp #[(number) "┴Vç" [number 0] 2 "\
  376. True if NUMBER is strictly greater than zero."])
  377. (fset 'minusp #[(number) "┴Wç" [number 0] 2 "\
  378. True if NUMBER is strictly less than zero."])
  379. (fset 'oddp #[(number) "┴ª┬U?ç" [number 2 0] 2 "\
  380. True if INTEGER is not divisible by 2."])
  381. (fset 'evenp #[(number) "┴ª┬Uç" [number 2 0] 2 "\
  382. True if INTEGER is divisible by 2."])
  383. (fset 'abs #[(number) "┴W½â[çç" [number 0] 2 "\
  384. Return the absolute value of NUMBER."])
  385. (fset 'signum #[(number) "┴W½é┬ç┴V½é├ç┴ç" [number 0 -1 1] 2 "\
  386. Return -1, 0 or 1 according to the sign of NUMBER."])
  387. (fset 'gcd #[(&rest integers) "Gë┬U½ä┬éÅ    ├U½å─@!¬°    ┼V½É╞╟ë@A@\"AAB\"¬π@A@_┬U½ä╚╔!ê─@!\n─A@! \n ] \n ^┬┬╨┬¼ª Ñ ªë┬U½ë╙¬` ¬V.)ç" [integers howmany 0 1 abs 2 apply gcd error "A zero argument is invalid for `gcd'" absa absb dd ds q r nil done result t] 6 "\
  388. Return the greatest common divisor of all the arguments.
  389. The arguments must be integers.  With no arguments, value is zero."])
  390. (fset 'lcm #[(integer &rest more) "G    @┬Aë╚U½å╔!¬¿╩V½î╦╠ë\" B\"¬û_ë╚U½â╚¬ë╔ !═\"Ñ-ç" [more integer nil yetmore prod b a howmany 0 abs 1 apply lcm gcd] 6 "\
  391. Return the least common multiple of all the arguments.
  392. The arguments must be integers and there must be at least one of them."])
  393. (fset 'isqrt #[(number) "└    !½à┬├    \"ç    ─U½é─ç┼─╚        ¼á    Ñ\\╩ÑëU«ç┼\\U    ¬\\ë_    V½å┼Z¬é+ç" [minusp number error "Argument to `isqrt' (%d) must not be negative" 0 1 approx new nil done 2] 4 "\
  394. Return the integer square root of NUMBER.
  395. NUMBER must not be negative.  Result is largest integer less than or
  396. equal to the real square root of the argument."])
  397. (fset 'floor #[(number &optional divisor) "¼ë    º½à┬    ├\"ç─╞ ë╚    \"Lê½å╔\n!¬î╦JC\n╔\n!) ═ 8 A@ @├U½å┬├ë\"¬«╤!½ê┬\"¬á├U½ê┬[├\"¬Æ╦\\[┬    _Z\"),ç" [divisor number values 0 nil *mvalues-count* gensym it safe-idiv copy-sequence *mvalues-values* 1 T$$_25 2 s r q plusp] 6 "\
  398. Divide DIVIDEND by DIVISOR, rounding toward minus infinity.
  399. DIVISOR defaults to 1.  The remainder is produced as a second value."])
  400. (fset 'ceiling #[(number &optional divisor) "¼ë    º½à┬    ├\"ç─╞ ë╚    \"Lê½å╔\n!¬î╦JC\n╔\n!) ═ 8 A@ @├U½å┬├ë\"¬¿╤!½ê┬\"¬Ü├U¼Ä╦\\    _Z┬\",ç" [divisor number values 0 nil *mvalues-count* gensym it safe-idiv copy-sequence *mvalues-values* 1 T$$_26 2 s r q minusp] 5 "\
  401. Divide DIVIDEND by DIVISOR, rounding toward plus infinity.
  402. DIVISOR defaults to 1.  The remainder is produced as a second value."])
  403. (fset 'truncate #[(number &optional divisor) "¼ë    º½à┬    ├\"ç─╞ ë╚    \"Lê½å╔\n!¬î╦JC\n╔\n!) ═ 8 A@ @├U½å┬├ë\"¬º╤!½ê┬\"¬Ö├U¼ì[    _Z┬\",ç" [divisor number values 0 nil *mvalues-count* gensym it safe-idiv copy-sequence *mvalues-values* 1 T$$_27 2 s r q plusp] 5 "\
  404. Divide DIVIDEND by DIVISOR, rounding toward zero.
  405. DIVISOR defaults to 1.  The remainder is produced as a second value."])
  406. (fset 'round #[(number &optional divisor) "¼ë    º½à┬    ├\"ç─╞ ë╚    \"Lê½å╔\n!¬î╦JC\n╔\n!) ═ 8 A@ @╤!╤!ZV½ê╦\\¬ôU½î╙!½å╦\\_    _Z┬\"-ç" [divisor number values 0 nil *mvalues-count* gensym it safe-idiv copy-sequence *mvalues-values* 1 T$$_28 2 s r q abs other-r oddp] 5 "\
  407. Divide DIVIDEND by DIVISOR, rounding to nearest integer.
  408. DIVISOR defaults to 1.  The remainder is produced as a second value."])
  409. (fset 'mod #[(number divisor) "└┬ ë─\"Lê    ½å╟!¬ï╔ JC╟!)ë\nA@ \n@  +ç" [nil *mvalues-count* gensym it floor number divisor copy-sequence *mvalues-values* 1 T$$_29 r q] 5 "\
  410. Return remainder of X by Y (rounding quotient toward minus infinity).
  411. That is, the remainder goes with the quotient produced by `floor'."])
  412. (fset 'rem #[(number divisor) "└┬ ë─\"Lê    ½å╟!¬ï╔ JC╟!)ë\nA@ \n@  +ç" [nil *mvalues-count* gensym it truncate number divisor copy-sequence *mvalues-values* 1 T$$_30 r q] 5 "\
  413. Return remainder of X by Y (rounding quotient toward zero).
  414. That is, the remainder goes with the quotient produced by `truncate'."])
  415. (fset 'safe-idiv #[(a b) "º½ä    º¼ä┬├!ê    ─U½à┬┼\"ê╞!╞    !Ñ    ╩!╩    !_      _    _Z ═      #-ç" [a b error "Arguments to `safe-idiv' must be numbers" 0 "Cannot divide %d by zero" abs absa absb q signum s r values] 4 "\
  416. SAFE-IDIV A B => Q R S
  417. Q=|A|/|B|, R is the rest, S is the sign of A/B."])
  418. (byte-code "└┴└ç" [:setf-update-fn :setf-update-doc] 1)
  419. (fset 'setf '(macro . #[(&rest pairs) "Gë┬ª├U¼å─┼!é    ├U½ä╞é    ┬V½╝╟ë@    ╩! ╞ ═!¼¥╬     E B ╧!ë@    ╩! ¬] ƒ,Bé@    ╩! ╞╞    9½ë╥     Eé    <â    @ëâ9âNëâ:½ç@╘=¼ú9½½╒!½ÑK╫!«è:¡à@╘=)½ì╪    A C\"B¬╦╞┌ ë▄╪    A C\"!Lê½å▌!¬ì▀JC▌!)ë A@! @\"π\"!BE+¬ç─Σσ    !\",)ç" [pairs nforms 2 0 error "Odd number of arguments to `setf'" nil progn args place cadr value result endp setf cddr head updatefn setq :setf-update-fn lambda fboundp defn subrp append *mvalues-count* gensym it pair-with-newsyms copy-sequence *mvalues-values* 1 T$$_31 newsyms bindings let "No `setf' update-function for `%s'" prin1-to-string] 6 "\
  420. Generalized `setq' that can set things other than variable values.
  421. A use of `setf' looks like (setf {PLACE VALUE}...).
  422. The behavior of (setf PLACE VALUE) is to access the generalized variable
  423. at PLACE and store VALUE there.  It returns VALUE.  If there is more
  424. than one PLACE and VALUE, each PLACE is set from its VALUE before
  425. the next PLACE is evaluated."]))
  426. (fset 'defsetf '(macro . #[(accessfn updatefn &optional docstring) "9¼ç┴┬├!\"ê─┼╞D╟╞DF┼╞D╔\nFEç" [accessfn error "First argument of `defsetf' must be a symbol, not `%s'" prin1-to-string progn put quote ':setf-update-fn updatefn ':setf-update-doc docstring] 6 "\
  427. Define how `setf' works on a certain kind of generalized variable.
  428. A use of `defsetf' looks like (defsetf ACCESSFN UPDATEFN [DOCSTRING]).
  429. ACCESSFN is a symbol.  UPDATEFN is a function or macro which takes
  430. one more argument than ACCESSFN does.  DEFSETF defines the translation
  431. of (SETF (ACCESFN . ARGS) NEWVAL) to be a form like (UPDATEFN ARGS... NEWVAL).
  432. The function UPDATEFN must return its last arg, after performing the
  433. updating called for."]))
  434. (byte-code "└┴┬├#ê└┴─┼#ê└╞┬╟#ê└╞─╚#ê└╔┬╩#ê└╔─╦#ê└╠┬═#ê└╠─╬#ê└╧┬╨#ê└╧─╤#ê└╥┬╙#ê└╥─╘#ê└╒┬╓#ê└╒─╫#ê└╪┬┘#ê└╪─┌#ê└█┬▄#ê└█─▌#ê└▐┬▀#ê└▐─α#ê└ß┬Γ#ê└ß─π#ê└Σ┬σ#ê└Σ─µ#ê└τ┬Φ#ê└τ─Θ#ê└Ω┬δ#ê└Ω─∞#ê└φ┬ε#ê└φ─∩#ê└≡┬±#ê└≡─≥#ê└≤┬⌠#ê└≤─⌡#ê└÷┬≈#ê└÷─°#ê└∙┬·#ê└∙─√#ê└ⁿ┬²#ê└ⁿ─■#ê└ ┬ü@#ê└ ─üA#ê└üB┬üC#ê└üB─üD#ê└üE┬üF#ê└üE─üG#ê└üH┬üI#ê└üH─üJ#ê└üK┬üL#ê└üK─üM#ê└üN┬üO#ê└üN─üP#ê└üQ┬üR#ê└üQ─üS#ê└üT┬üU#ê└üT─üV#ê└üW┬üX#ê└üW─üY#ê└üZ┬ü[#ê└üZ─ü\\#ê└ü]┬ü^#ê└ü]─ü_#ê└ü`┬üa#ê└ü`─üb#ê└üc┬üd#ê└üc─üe#ê└üf┬üg#ê└üf─üh#ê└üi┬üj#ê└üi─ük#ê└ül┬üm#ê└ül─ün#ê└üo┬üp#ê└üo─üq#ê└ür┬üs#ê└ür─üt#ê└üu┬üv#ê└üu─üw#ê└üx┬üy#ê└üx─üz#ê└ü{┬ü|#ê└ü{─ü}#ê└ü~┬ü#ê└ü~─üÇ#ê└üü┬üé#ê└üü─üâ#ê└üä┬üà#ê└üä─üå#ê└üç┬üê#ê└üç─üë#ê└üè┬üï#ê└üè─üî#ê└üì┬└#ê└üì─üÄ#ê└üÅ┬üÉ#ê└üÅ─üæ#ê└üÆ┬üô#ê└üÆ─üö#ê└üò┬üû#ê└üò─üù#ç" [put apply :setf-update-fn (lambda (&rest args) (let* ((fnform (car args)) (applyargs (append (apply 'list* (butlast (cdr args))) (last args))) (newupdater nil)) (cond ((and (symbolp fnform) (setq newupdater (get fnform :setf-update-fn))) (apply newupdater applyargs)) (t (error "Can't `setf' to `%s'" (prin1-to-string fnform)))))) :setf-update-doc "`apply' is a special case for `setf'" aref aset "`setf' inversion for `aref'" nth setnth "`setf' inversion for `nth'" nthcdr setnthcdr "`setf' inversion for `nthcdr'" elt setelt "`setf' inversion for `elt'" first (lambda (list val) (setnth 0 list val)) "`setf' inversion for `first'" second (lambda (list val) (setnth 1 list val)) "`setf' inversion for `second'" third (lambda (list val) (setnth 2 list val)) "`setf' inversion for `third'" fourth (lambda (list val) (setnth 3 list val)) "`setf' inversion for `fourth'" fifth (lambda (list val) (setnth 4 list val)) "`setf' inversion for `fifth'" sixth (lambda (list val) (setnth 5 list val)) "`setf' inversion for `sixth'" seventh (lambda (list val) (setnth 6 list val)) "`setf' inversion for `seventh'" eighth (lambda (list val) (setnth 7 list val)) "`setf' inversion for `eighth'" ninth (lambda (list val) (setnth 8 list val)) "`setf' inversion for `ninth'" tenth (lambda (list val) (setnth 9 list val)) "`setf' inversion for `tenth'" rest (lambda (list val) (setcdr list val)) "`setf' inversion for `rest'" car setcar "Replace the car of a cons" cdr setcdr "Replace the cdr of a cons" caar (lambda (list val) (setcar (nth 0 list) val)) "`setf' inversion for `caar'" cadr (lambda (list val) (setcar (cdr list) val)) "`setf' inversion for `cadr'" cdar (lambda (list val) (setcdr (car list) val)) "`setf' inversion for `cdar'" cddr (lambda (list val) (setcdr (cdr list) val)) "`setf' inversion for `cddr'" caaar (lambda (list val) (setcar (caar list) val)) "`setf' inversion for `caaar'" caadr (lambda (list val) (setcar (cadr list) val)) "`setf' inversion for `caadr'" cadar (lambda (list val) (setcar (cdar list) val)) "`setf' inversion for `cadar'" cdaar (lambda (list val) (setcdr (caar list) val)) "`setf' inversion for `cdaar'" caddr (lambda (list val) (setcar (cddr list) val)) "`setf' inversion for `caddr'" cdadr (lambda (list val) (setcdr (cadr list) val)) "`setf' inversion for `cdadr'" cddar (lambda (list val) (setcdr (cdar list) val)) "`setf' inversion for `cddar'" cdddr (lambda (list val) (setcdr (cddr list) val)) "`setf' inversion for `cdddr'" caaaar (lambda (list val) (setcar (caaar list) val)) "`setf' inversion for `caaaar'" caaadr (lambda (list val) (setcar (caadr list) val)) "`setf' inversion for `caaadr'" caadar (lambda (list val) (setcar (cadar list) val)) "`setf' inversion for `caadar'" cadaar (lambda (list val) (setcar (cdaar list) val)) "`setf' inversion for `cadaar'" cdaaar (lambda (list val) (setcdr (caar list) val)) "`setf' inversion for `cdaaar'" caaddr (lambda (list val) (setcar (caddr list) val)) "`setf' inversion for `caaddr'" cadadr (lambda (list val) (setcar (cdadr list) val)) "`setf' inversion for `cadadr'" cdaadr (lambda (list val) (setcdr (caadr list) val)) "`setf' inversion for `cdaadr'" caddar (lambda (list val) (setcar (cddar list) val)) "`setf' inversion for `caddar'" cdadar (lambda (list val) (setcdr (cadar list) val)) "`setf' inversion for `cdadar'" cddaar (lambda (list val) (setcdr (cdaar list) val)) "`setf' inversion for `cddaar'" cadddr (lambda (list val) (setcar (cdddr list) val)) "`setf' inversion for `cadddr'" cddadr (lambda (list val) (setcdr (cdadr list) val)) "`setf' inversion for `cddadr'" cdaddr (lambda (list val) (setcdr (caddr list) val)) "`setf' inversion for `cdaddr'" cdddar (lambda (list val) (setcdr (cddar list) val)) "`setf' inversion for `cdddar'" cddddr (lambda (list val) (setcdr (cddr list) val)) "`setf' inversion for `cddddr'" get "`setf' inversion for `get' is `put'" symbol-function fset "`setf' inversion for `symbol-function' is `fset'" symbol-plist setplist "`setf' inversion for `symbol-plist' is `setplist'" symbol-value set "`setf' inversion for `symbol-value' is `set'"] 4)
  435. (fset 'incf '(macro . #[(ref &optional delta) "¼é┴┬ ─ EEç" [delta 1 setf ref +] 5 "\
  436. (incf REF [DELTA]) -> increment the g.v. REF by DELTA (default 1)"]))
  437. (fset 'decf '(macro . #[(ref &optional delta) "¼é┴┬ ─ EEç" [delta 1 setf ref -] 5 "\
  438. (decf REF [DELTA]) -> decrement the g.v. REF by DELTA (default 1)"]))
  439. (fset 'push '(macro . #[(item ref) "└    ┬     EEç" [setf ref cons item] 5 "\
  440. (push ITEM REF) -> cons ITEM at the head of the g.v. REF (a list)"]))
  441. (fset 'pushnew '(macro . #[(item ref) "└    ┬     EEç" [setf ref adjoin item] 5 "\
  442. (pushnew ITEM REF): adjoin ITEM at the head of the g.v. REF (a list)"]))
  443. (fset 'pop '(macro . #[(ref) "└ ┬     DC─┼    D╞ ╟    DEEE)ç" [gensym listname let ref prog1 car setf cdr] 8 "\
  444. (pop REF) -> (prog1 (car REF) (setf REF (cdr REF)))"]))
  445. (fset 'psetf '(macro . #[(&rest pairs) "└    G!¼ä┬├!ê─╞ ë╚    !Lê½å╔\n!¬î╦JC\n╔\n!)ë A@ @─╞ ë╧!Lê½å╔\n!¬î╦JC\n╔\n!)ëA@@╙╘╒\"B─F.ç" [evenp pairs error "Odd number of arguments to `psetf'" nil *mvalues-count* gensym it unzip-list copy-sequence *mvalues-values* 1 T$$_32 forms places pair-with-newsyms T$$_33 newsyms bindings let setf zip-lists] 7 "\
  446. (psetf {PLACE VALUE}...): Set several generalized variables in parallel.
  447. All the VALUEs are computed, and then all the PLACEs are stored as in `setf'.
  448. See also `psetq', `shiftf' and `rotatef'."]))
  449. (fset 'shiftf '(macro . #[(&rest forms) "G┴V¼ä┬├!ê─!┼!@╚    ╩ ë ╠!Lê    ½å═!¬ì┴     JC═!)ëA@@╥╙╘╒AC\"\"B@F-ç" [forms 1 error "`shiftf' needs more than one argument" butlast last newvalue places nil *mvalues-count* gensym it pair-with-newsyms copy-sequence *mvalues-values* T$$_34 newsyms bindings let setf zip-lists append] 9 "\
  450. (shiftf PLACE1 PLACE2... NEWVALUE): set PLACE1 to PLACE2, PLACE2 to PLACE3...
  451. Each PLACE is set to the old value of the following PLACE,
  452. and the last PLACE is set to the value NEWVALUE."]))
  453. (fset 'rotatef '(macro . #[(&rest places) "¼é┴ç┴├ ë┼!Lê\n½å╞!¬ï╚ JC╞!)ë    A@\n    @ ╠ ═╬╧\nA\n@C\"\"B┴F+ç" [places nil *mvalues-count* gensym it pair-with-newsyms copy-sequence *mvalues-values* 1 T$$_35 newsyms bindings let setf zip-lists append] 9 "\
  454. (rotatef PLACE...) sets each PLACE to the old value of the following PLACE.
  455. The last PLACE is set to the old value of the first PLACE.
  456. Thus, the values rotate through the PLACEs."]))
  457. (byte-code "└┴┬├─┼╞╟╚╔    ╩\n╦ ╠ └ç" [:include :named :conc-name :copier :predicate :print-function :type :initial-offset :structure-doc :structure-slotsn :structure-slots :structure-indices :structure-initforms] 1)
  458. (fset 'defstruct '(macro . #[(&rest args) "└┬ ë─!Lê    ½å╞!¬ï╚ JC╞!)    ╩    8 ╠    8╬    8╨    8    A@    @└┬ ë╘#Lê    ½å╞!¬ï╚ JC╞!)╓8╩8╠8╬8╨8A@@º½¥▐V½ù\\▀\"▀ \" ▐V¼êαßΓ!\"êπ!ë$½êασΓ$!\"ê)µ \" └ëëëëë'()*+,φεD/FφεD0FφεD1εDFφεD2ε DFφεD3ε⌠ !DF»,⌡εD÷≈°┼D∙εD┼EEDE⌡εD÷≈·C√·DEDE⌡εD÷≈ⁿC²■ⁿD ü@ⁿ▐EεDEüAüBⁿDTEFEDEE+└┬ ëüC%Lê    ½å╞!¬ï╚ JC╞!)D╨D8*DA@(D@))üEüFüGB\"BC'üH,+ñ*ñ)ñ(ñ'ñ.Bç" [nil *mvalues-count* gensym it parse$defstruct$args args copy-sequence *mvalues-values* 1 T$$_36 5 initlist 4 slots 3 slotsn 2 docstring options name parse$defstruct$options T$$_37 6 moreinits moreslots moreslotsn predicate copier constructor conc-name 0 append error "%s needs at least one slot" prin1-to-string duplicate-symbols-p dups "`%s' are duplicates" simplify$inits returned alterators accessors keywords functions properties put quote :structure-doc :structure-slotsn :structure-slots :structure-initforms :structure-indices extract$indices fset function lambda &rest make$structure$instance struct copy-vector thing and vectorp eq elt = length build$accessors$for T$$_38 vector mapcar #[(x) "└    Dç" [quote x] 2] progn] 14 "\
  459. (defstruct NAME [DOC-STRING] . SLOTS)  define NAME as structure type.
  460. NAME must be a symbol, the name of the new structure.  It could also
  461. be a list (NAME . OPTIONS), but not all options are supported currently.
  462. As of Dec. 1986, this is supporting :conc-name, :copier and :predicate
  463. completely, :include arguably completely and :constructor only to
  464. change the name of the default constructor.  No BOA constructors allowed.
  465. The DOC-STRING is established as the 'structure-doc' property of NAME.
  466. The SLOTS are one or more of the following:
  467. SYMBOL -- meaning the SYMBOL is the name of a SLOT of NAME
  468. list of SYMBOL and VALUE -- meaning that VALUE is the initial value of
  469. the slot.
  470. `defstruct' defines functions `make-NAME', `NAME-p', `copy-NAME' for the
  471. structure, and functions with the same name as the slots to access
  472. them.  `setf' of the accessors sets their values."]))
  473. (fset 'parse$defstruct$args #[(args) "└ë┴└┬└ë    \n@9½è\n@    └¬ƒ\n@<½ò╦\n!9½Ä╦\n!    ╠\n!¬ä═╬!ê\nAë@;½è@A└╨ ë╥!Lê½å╙!¬ì╒JC╙!)╫8A@@╪     &. ç" [nil "" 0 initlist slots slotsn slotargs docstring options name args caar cdar error "First arg to `defstruct' must be symbol or (symbol ...)" *mvalues-count* gensym it process$slots copy-sequence *mvalues-values* 1 T$$_39 2 values] 8 "\
  474. PARSE$DEFSTRUCT$ARGS ARGS => NAME OPTIONS DOCSTRING SLOTSN SLOTS INITLIST
  475. NAME=symbol, OPTIONS=list of, DOCSTRING=string, SLOTSN=count of slots,
  476. SLOTS=list of their names, INITLIST=alist (keyword . initform)."])
  477. (fset 'process$slots #[(slots) "G┴ëë@╟!¼═9½É B╚╔!┴\n#¬»<½ó@9½£@╩! ë B╚╔ ! \n#*¬ê═╬╧!\"êAë@¬.*╨ ƒ\nƒ#+ç" [slots nil initlist slotslist slotsn ptr this endp acons keyword-of cadr form name error "Slot should be symbol or (symbol ...), not `%s'" prin1-to-string values] 5 "\
  478. PROCESS$SLOTS SLOTS => SLOTSN SLOTSLIST INITLIST
  479. Converts a list of symbols or lists of symbol and form into the last 3
  480. values returned by PARSE$DEFSTRUCT$ARGS."])
  481. (fset 'parse$defstruct$options #[(name options slots) "└    !ë├P┼╞\nP!┼╚\nP!    ┼\n╩P! ╠╬╬╬╬╬╬╬╬╫╪\"ê┌      &.ç" [symbol-name name namestring "-" conc-name intern "make-" const "copy-" copier "-p" pred 0 moreslotsn nil moreslots moreinits option-head option-second option-rest these-slotsn these-slots these-inits mapcar #[(option) "└    !½Å    ë├=«å─┼╞    !\")ç    <âb└    @ë!âb╚    !        AA\në ╠=½¥    ;½ä    ¬Ä    ¼â═¬ç─╬╞    !\"ëé` ╨=½Ö    9½ê\n¼ä    ¬å─┼╞    !\"ëé` ╥=½Ö    9½ê\n¼ä    ¬å─┼╞    !\"ëé` ╘=½Ö    9½ê\n¼ä    ¬å─┼╞    !\"ëé` ╓=âS    9¼ê─╫╞    !\"ê    N    N    Nº½å▐V¼ê─▀╞    !\"êα!Γ ë#Σ\n!Lê!½åσ&!¬ìτ!#JC&σ&!)(Θ(8*(A@+(@ë,▐V½Äφε+\"ê∩*\"0\\0∩1\"1∩2\"ë2,¬ì≤ ⌠\"«å─┼╞    !\")ç─┼╞    !\"ç" [keywordp option T$$_40 :named error "Can't recognize option `%s'" prin1-to-string option-head second option-second option-rest T$$_41 :conc-name "" "`%s' is invalid as `conc-name'" conc-name :copier copier :constructor const :predicate pred :include "Arg to `:include' should be a symbol, not `%s'" :structure-slotsn these-slotsn :structure-slots these-slots :structure-initforms these-inits 0 "`%s' is not a valid structure" nil *mvalues-count* gensym it process$slots copy-sequence *mvalues-values* 1 T$$_42 2 xtra-inits xtra-slots xtra-slotsn mapcar #[(xslot) "    >?¡ë┬├─!─!#ç" [xslot these-slots error "`%s' is not a slot of `%s'" prin1-to-string option-second] 5] append moreslotsn moreslots moreinits cl-member (:print-function :type :initial-offset)] 5] options values] 9 "\
  482. PARSE$DEFSTRUCT$OPTIONS NAME OPTIONS SLOTS => CONC-NAME CONST COPIER PRED
  483. Returns at least those 4 values (a string and 3 symbols, to name the necessary
  484. functions),  might return also things discovered by actually
  485. inspecting the options, namely MORESLOTSN MORESLOTS MOREINITS, as can
  486. be created by :include, and perhaps a list of BOACONSTRUCTORS."])
  487. (fset 'simplify$inits #[(slots initlist) "└ë├─\"ê\nƒ*ç" [nil key result mapcar #[(slot) "└    !├\n─\n\"A#ëç" [keyword-of slot key acons assoc initlist result] 5] slots] 3 "\
  488. SIMPLIFY$INITS SLOTS INITLIST => new INITLIST
  489. Removes from INITLIST - an ALIST - any shadowed bindings."])
  490. (fset 'extract$indices #[(initlist) "└┴─┼\"ê└ ƒ+ç" [nil 0 index result mapcar #[(entry) "└    @\n #\n─\\ëç" [acons entry index result 1] 4] initlist entry] 3 "\
  491. EXTRACT$INDICES INITLIST => indices list
  492. Kludge.  From a list of pairs (keyword . form) build a list of pairs
  493. of the form (keyword . position in list from 0).  Useful to precompute
  494. some of the work of MAKE$STRUCTURE$INSTANCE."])
  495. (fset 'build$accessors$for #[(name conc-name predicate slots slotsn) "└┴ëë┬Y¼÷╔\n╦ 8!P!═╬ D╧╨╤C╥╤D╘╤TED╒╓╫╪╤D╪╬DDFDEEDEB┌ ╨╤█D╥╤D▄╤T█FD╒╓▌╪╤D╪╬DDFDEEEB▐▀ 8!D BTë )¬ßƒƒ ƒ#-ç" [0 nil "" canonic keywords alterators accessors i slotsn intern conc-name symbol-name slots fset quote function lambda object cond predicate aref t error "`%s' not a %s." prin1-to-string name defsetf newval aset "`%s' not a `%s'" defkeyword keyword-of G$$_13 values] 15 "\
  496. BUILD$ACCESSORS$FOR NAME PREDICATE SLOTS SLOTSN  => FSETS DEFSETFS KWDS
  497. Generate the code for accesors and defsetfs of a structure called
  498. NAME, whose slots are SLOTS.  Also, establishes the keywords for the
  499. slots names."])
  500. (fset 'make$structure$instance #[(name args) "9¼ç┴┬├!\"ê NNN╟ë    \n   º½å ═V¼ç┴╬├!\"ê╧G!¼ê┴╤├!\"ê╟╙ ë╒!Lê½å╓!¬ì╪JC╓!)ëA@@▄▌\"¼ê┴▐├!\"ê▀α\"êßë\"@#╟$σ\"!¼öµ#D$B$\"Aë\"@#¬f$ƒ+╓ !#    \n\"τ\"!(╟$σ\"!¼¢ΘΩ(    \"A!$B$\"A\"τ\"!(¬_$ƒ+δ∞B\".ç" [name error "`%s' is not a possible name for a structure" prin1-to-string :structure-initforms :structure-slotsn :structure-indices nil initializers initalist indices slotsn initforms 0 "`%s' is not a defined structure" evenp args "Slot initializers `%s' not of even length" *mvalues-count* gensym it unzip-list copy-sequence *mvalues-values* 1 T$$_43 specvals speckwds every keywordp "All of the names in `%s' should be keywords" mapcar #[(kwd) "└    \n\"Aº?¡è├─┼    !┼!#ç" [assoc kwd indices error "`%s' is not a valid slot name for %s" prin1-to-string name] 5] pairlis ptr val result endp quote caar key eval assoc apply vector] 6 "\
  501. MAKE$STRUCTURE$INSTANCE NAME ARGS => new struct NAME
  502. A struct of type NAME is created, some slots might be initialized
  503. according to ARGS (the &rest argument of MAKE-name)."])
  504.